package com.zhiwang.xiaoqu.mvp.model.request

import com.google.gson.annotations.SerializedName

//获取短信验证码
class SmsCodeRequest(
    @SerializedName("phone") var phone: String,
    @SerializedName("tu_vcode") var graphCode: String,
    @SerializedName("tu_token") var randomStr: String
) {

    @SerializedName("vcode_type")
    lateinit var type: String

    fun setTypeRegister() {
        type = "app_reg"
    }

    fun setTypeFind() {
        type = "app_findpwd"
    }

    fun setTypeChange() {
        type = "app_changepwd"
    }

    fun setTypeBind() {
        type = "app_bind"
    }
}

data class LoginRequest(var username: String, var password: String, var deviceId: String) {
    var get_token = 1
}

data class BindAliAccountRequest(
    @SerializedName("alipay")
    var phone: String,
    @SerializedName("tu_vcode")
    var graphCode: String,
    @SerializedName("alipay_name")
    var account: String,
    @SerializedName("vcode")
    var sms: String
)

data class PageRequest(var page: Int)


/**
 * [type] weixin/alipay
 */
data class WithDrawRequest(
    var number: String,
    @SerializedName("cash_type")
    var type: String
)